package com.xiaolin.po;

import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import javax.persistence.Column;
import javax.persistence.Id;
import java.util.Date;

@Document(indexName = "bilibili",type = "docs",shards = 5,replicas = 1)
public class Video {

    @Id
    @org.springframework.data.annotation.Id
    private Integer aid;
    private Integer videos;
    private Integer tid;

    @Field(type = FieldType.Keyword)
    private String tname;
    private Integer copyright;
    private String pic;

    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    private String title;
    private Date pubdate;
    private Date ctime;

    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    @Column(name = "desc_ribe")
    private String desc;
    private Integer state;
    private Integer attribute;
    private Integer duration;
    private String dynamic;
    private Integer cid;
    private Boolean no_cache;
    private String embedPlayer;

    public Integer getAid() {
        return aid;
    }

    public void setAid(Integer aid) {
        this.aid = aid;
    }

    public Integer getVideos() {
        return videos;
    }

    public void setVideos(Integer videos) {
        this.videos = videos;
    }

    public Integer getTid() {
        return tid;
    }

    public void setTid(Integer tid) {
        this.tid = tid;
    }

    public String getTname() {
        return tname;
    }

    public void setTname(String tname) {
        this.tname = tname;
    }

    public Integer getCopyright() {
        return copyright;
    }

    public void setCopyright(Integer copyright) {
        this.copyright = copyright;
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public Date getPubdate() {
        return pubdate;
    }

    public void setPubdate(Date pubdate) {
        this.pubdate = pubdate;
    }

    public Date getCtime() {
        return ctime;
    }

    public void setCtime(Date ctime) {
        this.ctime = ctime;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public Integer getAttribute() {
        return attribute;
    }

    public void setAttribute(Integer attribute) {
        this.attribute = attribute;
    }

    public Integer getDuration() {
        return duration;
    }

    public void setDuration(Integer duration) {
        this.duration = duration;
    }

    public String getDynamic() {
        return dynamic;
    }

    public void setDynamic(String dynamic) {
        this.dynamic = dynamic;
    }

    public Integer getCid() {
        return cid;
    }

    public void setCid(Integer cid) {
        this.cid = cid;
    }

    public Boolean getNo_cache() {
        return no_cache;
    }

    public void setNo_cache(Boolean no_cache) {
        this.no_cache = no_cache;
    }

    public String getEmbedPlayer() {
        return embedPlayer;
    }

    public void setEmbedPlayer(String embedPlayer) {
        this.embedPlayer = embedPlayer;
    }

    @Override
    public String toString() {
        return "Video{" +
                "aid=" + aid +
                ", videos=" + videos +
                ", tid=" + tid +
                ", tname='" + tname + '\'' +
                ", copyright=" + copyright +
                ", pic='" + pic + '\'' +
                ", title='" + title + '\'' +
                ", pubdate=" + pubdate +
                ", ctime=" + ctime +
                ", desc='" + desc + '\'' +
                ", state=" + state +
                ", attribute=" + attribute +
                ", duration=" + duration +
                ", dynamic='" + dynamic + '\'' +
                ", cid=" + cid +
                ", no_cache=" + no_cache +
                ", embedPlayer='" + embedPlayer + '\'' +
                '}';
    }
}
